﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>

<%@ Register Assembly="FlashControl" Namespace="Bewise.Web.UI.WebControls" TagPrefix="Bewise" %>
<script runat="server">
    
    protected void Page_Load(object sender, EventArgs e)
    {
        if (ViewData["id"] != null)
        {
            System.Collections.Specialized.NameValueCollection flashVarsCol = new System.Collections.Specialized.NameValueCollection();
            flashVarsCol.Add("port", (string)ViewData["port"]);
            flashVarsCol.Add("address", (string)ViewData["address"]);
            flashVarsCol.Add("id", (string)ViewData["id"]);
            FlashControl2.FlashVarsCollection = flashVarsCol;
            Timer1.Interval = int.MaxValue; //999999999;
            FlashControl2.Visible = true;
        }
        else FlashControl2.Visible = false;
    }      
    

</script>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    GameRoom
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="MainContent" runat="server">
    <h2>
        GameRoom</h2>
    
    <fieldset>
        <legend>Game</legend>
            <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
        <asp:Timer ID="Timer1" Interval="3000" runat="server">
        </asp:Timer>
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
            <ContentTemplate>
                    
            </ContentTemplate>
        </asp:UpdatePanel>
        </form>
            <Bewise:FlashControl ID="FlashControl2" runat="server" Height="500px" 
            MovieUrl="~/Ressources/BomberMan.swf" Width="500px" />
    </fieldset>
</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="alerts" runat="server">
</asp:Content>
